<!DOCTYPE html>
<html lang='zh-CN'>
<head>
    <meta charset="utf-8">
    <meta name="referrer" content="no-referrer" />
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" />
    <title>商品管理(全国)</title>
    <link rel="icon" href="favicon.ico" type="image/ico">
    <link href="css/bootstrap.min.css" rel="stylesheet">
    <link href="css/materialdesignicons.min.css" rel="stylesheet">
    <link href="css/animate.css" rel="stylesheet">
    <link href="css/style.min.css" rel="stylesheet">
    <link href="js/bootstrap-table/bootstrap-table.min.css" rel="stylesheet">
</head>
<body>
<div class="container-fluid p-t-15">

    <div class="row">
        <div class="col-md-12">
            <div class="card">
                <div class="card-body">

                    <ul id="myTabs" class="nav nav-tabs" role="tablist">
                        <li class="active" value="sale_data"><a href="#sale" id="sale-tab" role="tab" data-toggle="tab" onclick="tabChange(1,null)">出售中的商品(<span id="saleTotal">0</span>)</a></li>
                        <li value="reviewed_data"><a href="#reviewed" role="tab" id="reviewed-tab" data-toggle="tab" onclick="tabChange(0,null)">审核中的商品(<span id="reviewedTotal">0</span>)</a></li>
                        <li value="out_data"><a href="#out" role="tab" id="out-tab" data-toggle="tab" onclick="tabChange(100, 0)">已经售馨商品(<span id="outTotal">0</span>)</a></li>
                        <li value="warning_data"><a href="#warning" role="tab" id="warning-tab" data-toggle="tab" onclick="tabChange(200, 1)">库存警戒商品(<span id="warningTotal">0</span>)</a></li>
                        <li value="off_data"><a href="#off" role="tab" id="off-tab" data-toggle="tab" onclick="tabChange(4,null)">已经下架商品(<span id="offTotal">0</span>)</a></li>
                        <li value="unReviewed_data"><a href="#unReviewed" role="tab" id="unReviewed-tab" data-toggle="tab" onclick="tabChange(2,null)">审核不通过商品(<span id="unReviewedTotal">0</span>)</a></li>
                        <li value="delete_data"><a href="#delete" role="tab" id="delete-tab" data-toggle="tab" onclick="tabChange(5,null)">商品回收站(<span id="deleteTotal">0</span>)</a></li>
                    </ul>
                    <div id="myTabContent" class="tab-content">
                        <form class="form-inline" method="post" id="searchForm">
                            <div class="form-group">
                                <label>商品名称:</label>
                                <input type="hidden" class="form-control" name="status" value="1">
                                <input type="hidden" class="form-control" name="flags" value="">
                                <input type="text" class="form-control" name="productName">
                            </div>
                            <div class="form-group">
                                <label>商家名称:</label>
                                <input type="text" class="form-control" name="businessName">
                            </div>
                            <div class="form-group">
                                <label>销售区域:</label>
                                <input type="text" class="form-control" name="saleArea">
                            </div>
                            <div class="form-group">
                                <button class="btn btn-info btn_query btn-round" type="button" id="searchFormBtn">查询</button>
                                <button class="btn btn-success btn_query btn-round" type="button" id="addBtn">添加商品</button>
                            </div>
                        </form>

                        <div class="tab-pane fade active in table-responsive" id="sale">
                            <table id="sale_data" class="table text-nowrap"></table>
                        </div>
                        <div class="tab-pane fade table-responsive" id="reviewed">
                            <table id="reviewed_data" class="table text-nowrap"></table>
                        </div>
                        <div class="tab-pane fade table-responsive" id="out">
                            <table id="out_data" class="table text-nowrap"></table>
                        </div>
                        <div class="tab-pane fade table-responsive" id="warning">
                            <table id="warning_data" class="table text-nowrap"></table>
                        </div>
                        <div class="tab-pane fade table-responsive" id="off">
                            <table id="off_data" class="table text-nowrap"></table>
                        </div>
                        <div class="tab-pane table-responsive" id="unReviewed">
                            <table id="unReviewed_data" class="table text-nowrap"></table>
                        </div>
                        <div class="tab-pane table-responsive" id="delete">
                            <table id="delete_data" class="table text-nowrap"></table>
                        </div>
                    </div>

                </div>
            </div>
        </div>
    </div>

</div>

<!--  添加与编辑模态框 -->
<div class="modal fade" id="auditModal" tabindex="-1" role="dialog" aria-labelledby="exampleModalLabel">
    <div class="modal-dialog" role="document">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
                <h4 class="modal-title" id="exampleModalLabel">商品审核（社区）</h4>
            </div>
            <div class="modal-body">
                <form id="addOrEditForm" method="post">
                    <input type="hidden" name="ids">
                    <div class="form-group">
                        <label>审核状态</label>
                        <select class="form-control" name="productStatus">
                            <option value="1">审核通过</option>
                            <option value="2">审核不通过</option>
                        </select>
                    </div>
                    <div class="form-group">
                        <label>审核结果</label>
                        <textarea class="form-control" name="approveResult" rows="6" placeholder="填写审核结果.."></textarea>
                    </div>
                    <div class="modal-footer">
                        <button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
                        <button type="button" class="btn btn-primary" id="saveBtn">保存</button>
                    </div>
                </form>
            </div>
        </div>
    </div>
</div>

</body>
<#include "/footer.html"/>
<script type="text/javascript">

    //添加商品
    $("#addBtn").click(function () {
        zero2one.tab("添加商品(全国)","/toView?url=service/goods/addGoods",108);
    })

</script>

</html>
